using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.UI;

namespace LifeChess.GamePlay.Test
{
    public class GenBoardSizeInfoGet : MonoBehaviour
    {
        public BoardManager BoardManager;
        public InputField widthField;
        public InputField heightField;

        public void GenerateBoardBySize()
        {
            Vector2Int boardSize = new Vector2Int();
            if (widthField.text.Length != 0)
            {
                boardSize.x = int.Parse(widthField.text);
            }
            if (heightField.text.Length != 0)
            {
                boardSize.y = int.Parse(heightField.text);
            }
            BoardManager.GenerateChessBoard(boardSize);
        }
    }
}